package handler;

public class ErrorHandler extends Handler {
    @Override
    public void handleRequest(String request) {
        if (request.equals("error")) {
            System.out.println("错误处理: 停止设备运行");
        } else if (successor != null) {
            successor.handleRequest(request);
        }
    }
}